In the prior art, there is a power tool that includes a speed reduction mechanism, which decelerates and transmits the rotary power of a motor that is a driving source, and switches the speed reduction ratio by sliding a switching member of the speed reduction mechanism (for example, patent document 1).
The power tool of patent document 1 includes a gearshift actuator, which slides the switching member, a driving state detector, which detects a driving state of the motor, a slide position detector, which detects a position where the switching member slides, and a controller, which controls the driving of the gearshift actuator. The controller controls the driving of the gearshift actuator in correspondence with detection results of the driving state detector and the slide position detector to automatically switch the speed reduction ratio.
Additionally, as an example of the slide position detector, the fourth embodiment in patent document 1 illustrates a displacement sensor that detects a rotational state of a rotational gearshift actuator. The switching member moves in cooperation with the rotation of the gearshift actuator. Therefore, the displacement sensor indirectly detects the position of the switching member by detecting the rotational state of the gearshift actuator.
The movement distance of the switching member for switching the speed reduction ratio and the rotation angle of the gearshift actuator for moving the switching member are set in advance in correspondence with a number of speed reduction ratios. The displacement sensor is set so that when the rotation angle of the gearshift actuator from a predetermined initial position in the rotating direction reaches an angle that is needed to move the switching member, the displacement sensor generates a value that corresponds to the switched speed reduction ratio.
For example, the gearshift actuator rotates between a rotation angle corresponding to a low speed rotation mode for a large speed reduction ratio and a rotation angle corresponding to a high speed rotation mode for a small speed reduction ratio. When the rotation angle of the gearshift actuator reaches the rotation angle that corresponds to the low speed rotation mode, the displacement sensor generates a value that corresponds to the large speed reduction ratio. When the rotation angle of the gearshift actuator reaches the rotation angle that corresponds to the high speed rotation mode, the displacement sensor generates a value that corresponds to the small speed reduction ratio. Thus, based on the value provided from the displacement sensor, the controller determines the present speed reduction ratio and whether or not the switching of the speed reduction ratio has been completed.